package org.gp.core.entity;

import com.baomidou.mybatisplus.activerecord.Model;
import com.baomidou.mybatisplus.annotations.TableId;
import com.baomidou.mybatisplus.annotations.TableField;
import com.baomidou.mybatisplus.enums.IdType;
import lombok.Data;

import java.io.Serializable;

/**
 * <p>
 * 用户表
 * </p>
 *
 * @author LuoLiang
 * @since 2017-02-03
 */
@Data
public class User extends Model<User> {

    private static final long serialVersionUID = 1L;

    /**
     *
     */
    @TableId(value = "id")
    private Integer id;

    /**
     * 微信对用户的唯一OPENID
     */
    private String openid;

    /**
     * 用户性别
     */
    private Integer sex;

    /**
     *
     */
    private String age;

    /**
     * 用户昵称
     */
    private String nickname;

    /**
     * 国家
     */
    private String country;

    /**
     * 省份
     */
    private String province;

    /**
     * 城市
     */
    private String city;

    /**
     * 用户头像地址
     */
    private String headimgurl;

    @Override
    protected Serializable pkVal() {
        return null;
    }

    @Override
    public String toString() {
        return "User{" +
                "id=" + id +
                ", openid='" + openid + '\'' +
                ", sex=" + sex +
                ", age=" + age +
                ", nickname='" + nickname + '\'' +
                ", country='" + country + '\'' +
                ", province='" + province + '\'' +
                ", city='" + city + '\'' +
                ", headimgurl='" + headimgurl + '\'' +
                '}';
    }
}
